package vg.services.data_base_manager.data.header;

import vg.services.data_base_manager.realization.DataBaseFields;

public class AttributeHeader implements Cloneable {
	// Defines
	public static final int DEF_NO_OWNER_TYPE = DataBaseFields.ATTRIBUTE_TABLE_NONE_OWNER_TYPE;
	public static final int DEF_VERTEX_OWNER_TYPE = DataBaseFields.ATTRIBUTE_TABLE_VERTEX_OWNER_TYPE;
	public static final int DEF_EDGE_OWNER_TYPE = DataBaseFields.ATTRIBUTE_TABLE_EDGE_OWNER_TYPE;
	
	// Main data
	public int id;
	public String name;
	public Object value;
	public Class<?> type;
	public int owner_id;
	public int owner_type;
	
	public AttributeHeader(int id, int owner_id, int owner_type) {
		this.id = id;
		this.owner_id = owner_id;
		this.owner_type = owner_type;
	}
	
	@Override
	public AttributeHeader clone() {
		AttributeHeader a = new AttributeHeader(id, owner_id, owner_type);
		a.name = name;
		a.value = value;
		a.type = type;
		return a;
	}
}
